package com.xique.door.device.freeview.service.impl;


import com.xique.common.core.text.Convert;
import com.xique.door.device.freeview.bean.domain.FreeviewEventParam;
import com.xique.door.device.freeview.mapper.FreeviewEventParamMapper;
import com.xique.door.device.freeview.service.IFreeviewEventParamService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 全视通事件参数Service业务层处理
 * 
 * @author caogq
 * @date 2021-10-21
 */
@Service
public class FreeviewEventParamServiceImpl implements IFreeviewEventParamService
{
    @Autowired
    private FreeviewEventParamMapper freeviewEventParamMapper;

    /**
     * 查询全视通事件参数
     * 
     * @param id 全视通事件参数ID
     * @return 全视通事件参数
     */
    @Override
    public FreeviewEventParam selectFreeviewEventParamById(Long id)
    {
        return freeviewEventParamMapper.selectFreeviewEventParamById(id);
    }

    /**
     * 查询全视通事件参数列表
     * 
     * @param freeviewEventParam 全视通事件参数
     * @return 全视通事件参数
     */
    @Override
    public List<FreeviewEventParam> selectFreeviewEventParamList(FreeviewEventParam freeviewEventParam)
    {
        return freeviewEventParamMapper.selectFreeviewEventParamList(freeviewEventParam);
    }

    /**
     * 新增全视通事件参数
     * 
     * @param freeviewEventParam 全视通事件参数
     * @return 结果
     */
    @Override
    public int insertFreeviewEventParam(FreeviewEventParam freeviewEventParam)
    {
        return freeviewEventParamMapper.insertFreeviewEventParam(freeviewEventParam);
    }

    /**
     * 修改全视通事件参数
     * 
     * @param freeviewEventParam 全视通事件参数
     * @return 结果
     */
    @Override
    public int updateFreeviewEventParam(FreeviewEventParam freeviewEventParam)
    {
        return freeviewEventParamMapper.updateFreeviewEventParam(freeviewEventParam);
    }

    /**
     * 删除全视通事件参数对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    @Override
    public int deleteFreeviewEventParamByIds(String ids)
    {
        return freeviewEventParamMapper.deleteFreeviewEventParamByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除全视通事件参数信息
     * 
     * @param id 全视通事件参数ID
     * @return 结果
     */
    @Override
    public int deleteFreeviewEventParamById(Long id)
    {
        return freeviewEventParamMapper.deleteFreeviewEventParamById(id);
    }
}
